using UnityEngine;
using System.Collections;

public class FSM {
	
	private State current_state;
	
	public FSM()
	{
		
	}
	~FSM()
	{
		
	}
	
	public void Begin_state(State new_state,Alive_object _object)
	{
		current_state = new_state;
		
		new_state.Enter_State(_object);
	}
	public void Run_state(Alive_object _object)
	{
		current_state.Excute_State(_object);
	}
	public void Change_state(State new_state,Alive_object _object)
	{
		current_state.Exit_State(_object);
		
		current_state = new_state;
		
		current_state.Enter_State(_object);
	}
	
}
